package com.zf.museum.repository;

import com.zf.museum.model.SingleChoice;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface SingleChoiceRepository extends JpaRepository<SingleChoice, Long>{
    @Query("select id from SingleChoice order by id asc ")
    Long[] getIds();

    List<SingleChoice> getTop6ByIdIsNotIn(List<Long> ids);
}
